package com.yun;

public class Test3 {
    public static void main(String[] args) {
        Father f = new Son();
        System.out.println(f);
        f.t1();
        f.t2();

        Func func = ()->{
            return "true";
        };
        f.t3(()->{
            return "123456";
        });
        System.out.println(func);
    }
}

class Father{
    public static void t1(){
        System.out.println("father t1");
    }

    public void t2(){
        System.out.println("father t2");
    }

    public void t3(Func func){
        String s = func.func2();
        System.out.println(s);
    }
}

class Son extends Father{
    public static void t1(){
        System.out.println("Son t1");
    }

    public void t2(){
        System.out.println("Son t2");
    }
}

interface Func {
    //boolean func();
    String func2();
}

